<template>
    <el-table style="width: 100%;
    max-width:1200px;
    padding: 0px 0px 0px 300px;"
    stripe
      :data="tableData">
      <el-table-column
        prop="exam"
        label="考试名"
        width="180">
      </el-table-column>
      <el-table-column
        prop="name"
        label="姓名"
        width="180">
      </el-table-column>
      <el-table-column
        prop="score"
        label="成绩">
      </el-table-column>
    </el-table>
  </template>

  <script>
    import axios from 'axios'
    export default {
      data() {
        return {
          tableData: []
        }
      },
      mounted() {
        axios({
		    method: 'POST',
		    url: 'http://127.0.0.1:8084/searchscore',
            data:{uid:this.$store.state.id}
		}).then(res=>{
            this.tableData=res.data;
            console.log(res.data);
		});
      },
      methods:{

      },
    }
  </script>
<style>

</style>